package com.lambda;

import com.service.impl.HightTemp;
import org.junit.Test;

/**
 * @description: 温度检测测试
 * @projectName:Lambda
 * @see:com.lambda
 * @author:LXC
 * @createTime:2024/4/15 11:50
 * @version:1.0
 */
public class HightTempAysn {

    int count = 0;

    HightTemp[] hightTemps = {
            new HightTemp(89), new HightTemp(78), new HightTemp(67),
            new HightTemp(36), new HightTemp(58), new HightTemp(98),
            new HightTemp(85), new HightTemp(66), new HightTemp(36)
    };

    @Test
    public void testHightTemp(){
        count = com.service.impl.HightTempAysn.counter(hightTemps, HightTemp::sameTemp, new HightTemp(36));
        System.out.println(count);

        count = com.service.impl.HightTempAysn.counter(hightTemps, HightTemp::lessThanTemp, new HightTemp(98));
        System.out.println(count);
    }

}
